<ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://xmlns.jcp.org/jsf/html" xmlns:f="http://xmlns.jcp.org/jsf/core"
    xmlns:ui="http://xmlns.jcp.org/jsf/facelets" xmlns:p="http://primefaces.org/ui" template="/WEB-INF/template.xhtml">

    <ui:define name="content">
        <div class="content-section documentation">
            <h1>PrimeFlex</h1>
            <p><a href="https://primeflex.org/" target="_blank" rel="noopener noreferrer">PrimeFlex</a> is a CSS utility library featuring various helpers such as a grid system, flexbox, spacing, elevation and more. Although it is not required, it is highly
                recommended to add PrimeFlex as it is likely to need such utilities when developing applications with PrimeFaces.</p>

            <h5>Install</h5>
            <p>PrimeFlex is available at <a href="https://github.com/primefaces/primeflex" target="_blank" rel="noopener noreferrer">GitHub</a>. Download <i>primeflex.min.css</i>, add it to your application and include the path
                usign the <i>h:outputStylesheet</i> component.</p>
            <p>PrimeFaces Showcase refers to version 3.3.1 of PrimeFlex.</p>

<pre class="language-xml"><code>
&lt;h:outputStylesheet name="%YOUR_PATH%/primeflex.min.css" /&gt;
</code></pre>

        <p>Or use WebJars...</p>
       <pre class="language-xml"><code>
        &lt;dependency&gt;
           &lt;groupId>org.webjars.npm&lt;/groupId&gt;
           &lt;artifactId>primeflex&lt;/artifactId&gt;
           &lt;version>3.3.1&lt;/version&gt;
        &lt;/dependency&gt;
        
        &lt;h:outputStylesheet library="webjars" name="primeflex/3.3.1/primeflex.min.css" /&gt;
        </code></pre>

            <p>PrimeFlex is a lightweight library, still it is possible to pick the utilities you need to make the file even smaller. For this, you need to remove the include paths and
                create your own build by compiling it with SASS. For example, if you do not need to use the elevation utilities, comment it out and build your own file. Note that sass cli
                should be available in your system, refer to <a href="https://sass-lang.com/documentation/cli">documentation</a> for details.
            </p>

<pre class="language-css"><code>
@import './src/_variables';
@import './src/_grid';
@import './src/_formlayout';
@import './src/_display';
@import './src/_text';
@import './src/flexbox/_flexbox';
@import './src/_spacing';
@import './src/_elevation';

</code></pre>

<pre class="language-bash"><code>
sass --update primeflex.scss:primeflex.min.css --style compressed

</code></pre>

            <h5>Variables</h5>
            <p>Predefined values like breakpoints can be customized when creating your own build using the <i>src/_variables</i> file.</p>

            <div class="doc-tablewrapper">
                <table class="doc-table">
                    <thead>
                        <tr>
                            <th>Variable</th>
                            <th>Description</th>
                            <th>Default</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>$sm</td>
                            <td>Breakpoint of screens such as phones.</td>
                            <td>576px</td>
                        </tr>
                        <tr>
                            <td>$md</td>
                            <td>Breakpoint of screens such as tablets.</td>
                            <td>768px</td>
                        </tr>
                        <tr>
                            <td>$lg</td>
                            <td>Breakpoint of screens such as notebook monitors.</td>
                            <td>992px</td>
                        </tr>
                        <tr>
                            <td>$xl</td>
                            <td>Breakpoint of smaller screens such as desktop monitors.</td>
                            <td>1200px</td>
                        </tr>
                        <tr>
                            <td>$gutter</td>
                            <td>Padding of a grid column.</td>
                            <td>.5rem</td>
                        </tr>
                        <tr>
                            <td>$fieldMargin</td>
                            <td>Spacing of a field. Can be vertical of horizontal depending on form layout.</td>
                            <td>.5rem</td>
                        </tr>
                        <tr>
                            <td>$fieldLabelMargin</td>
                            <td>Spacing of a field label. Can be vertical of horizontal depending on form layout.</td>
                            <td>.5rem</td>
                        </tr>
                        <tr>
                            <td>$helperTextMargin</td>
                            <td>Top spacing of a helper text.</td>
                            <td>.5rem</td>
                        </tr>
                        <tr>
                            <td>$spacer</td>
                            <td>Base value to use in spacing utilities, view spacing documentation for details.</td>
                            <td>.5rem</td>
                        </tr>
                    </tbody>
                </table>
            </div>

        </div>
    </ui:define>
</ui:composition>
